package com.hsy.linemoney.modules.main.actionbar;

import android.content.Context;
import android.util.AttributeSet;
import android.view.ViewGroup;
import android.widget.RelativeLayout;

import com.hsy.linemoney.R;
import com.hsy.linemoney.modules.main.MainActivity;

/**
 * Created by Administrator on 2016/8/30.
 */
public class ExchangeActionBar extends RelativeLayout implements IActionBar {
    private MainActivity activity;

    public ExchangeActionBar(Context context) {
        super(context);
        init(context);
    }

    public ExchangeActionBar(Context context, AttributeSet attrs) {
        super(context, attrs);
    }

    public ExchangeActionBar(Context context, AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
    }

    @Override
    public void setActivity(MainActivity activity) {
        this.activity = activity;
    }


    private void init(Context context) {
        addView(inflate(context, R.layout.actionbar_exchange, null), new ViewGroup.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT));

    }
}
